package com.lifeng.service.api;

import com.lifeng.service.dto.UserDTO;
import com.lifeng.service.exception.BizException;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.Map;

/**
 * @author lifeng
 * @Description:
 * @date 2020/7/25 23:23
 */
@FeignClient("user-service-consul-provider")
public interface UserServiceFeign {
    @RequestMapping(value = "/save",method = RequestMethod.POST)
    public Map<String,Object> saveUserMap(@RequestBody UserDTO userDTO) throws BizException;

    @RequestMapping(value = "/add",method = RequestMethod.POST)
    public Map<String,Object> addUserMap(@RequestBody UserDTO userDTO);
}
